<?php 	

	class UriCache extends RedisMem {
        protected $prefix = "uri_20241101";

		/**
		 *
		 * @param $uri_key
		 * @return array|bool|mixed
		 */
		public function getUriCache($uri_key) {
            $uri_key = trim($uri_key);
			if (empty($uri_key)) {
				return array();
			}

			$cachekey = md5($this->prefix."getUriCache".$uri_key);
			//读缓存
			$data = $this->get_json($cachekey);
			if($data !== false){
				return $data;
			}
            $uriModule = new UriModule();
            $info = $uriModule->getUriByKey($uri_key);

			if (empty($info)) {
				$info = array();
			}
			//写缓存
			$this->set_json($cachekey, $info, 60);
			return $info;
		}

	}